package xyz.kongbai121.modules.sys.service;

import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.web.multipart.MultipartFile;
import xyz.kongbai121.common.utils.PageUtils;
import xyz.kongbai121.modules.sys.entity.FileUploadLocalEntity;

import java.io.IOException;
import java.util.Map;

/**
 * 文件上传(保存到本机)
 *
 * @author zbn
 * @email sunlightcs@gmail.com
 * @date 2021-11-29 13:36:08
 */
public interface FileUploadLocalService extends IService<FileUploadLocalEntity> {

    PageUtils queryPage(Map<String, Object> params);

    FileUploadLocalEntity downloadFromUrlAndSave(String httpUrl) throws IOException;

    FileUploadLocalEntity uploadAndSave(MultipartFile file) throws IOException;

}

